/**
 * Witontek.com.
 * Copyright (c) 2012-2016 All Rights Reserved.
 */
package test.thread;

/**
 * 
 * @author Long
 * @version $Id: Runnable1.java, v 0.1 2016年10月31日 下午2:14:59  xiaolong.ma  Exp $
 */
public class MyRunnable implements Runnable {

    private String name;

    /**
     * Getter method for property <tt>name</tt>.
     * 
     * @return property value of name
     */
    public String getName() {
        return name;
    }

    /**
     * Setter method for property <tt>name</tt>.
     * 
     * @param name value to be assigned to property name
     */
    public void setName(String name) {
        this.name = name;
    }

    /** 
     * @see java.lang.Runnable#run()
     */
    public void run() {
        System.out.println(name + " running!");
        try {
            Thread.sleep(10000);
            System.out.println("sleep!");
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        System.out.println(name + " end!");
    }

}
